home *** CD-ROM | disk | FTP | other *** search
- unit MainForm;
- interface
- uses
- Windows, Messages, SysUtils, Variants, Classes, Graphics, Controls, Forms,
- Dialogs, Rio, SoapHTTPClient, StdCtrls, ExtCtrls;
-
- type
- TForm1 = class(TForm)
- bntAnswer: TButton;
- btnQuestion: TButton;
- lbeAnswer: TLabeledEdit;
- lbeQuestion: TLabeledEdit;
- HTTPRIO1: THTTPRIO;
- procedure bntAnswerClick(Sender: TObject);
- procedure btnQuestionClick(Sender: TObject);
- private
- { Private declarations }
- public
- { Public declarations }
- end;
-
- var
- Form1: TForm1;
-
- implementation
- {$R *.dfm}
- uses
- HitchHikerImport;
-
- procedure TForm1.bntAnswerClick(Sender: TObject);
- var
- HitchHiker: IHitchHiker;
- begin
- HitchHiker := (HTTPRIO1 AS IHitchHiker);
- lbeAnswer.Text := IntToStr(HitchHiker.TheAnswer)
- end;
-
- procedure TForm1.btnQuestionClick(Sender: TObject);
- var
- HitchHiker: IHitchHiker;
- begin
- HitchHiker := (HTTPRIO1 AS IHitchHiker);
- lbeQuestion.Text := HitchHiker.TheQuestion
- end;
-
- end.
-